Bug 536990 - updateiconcache.c: 'close ()' is redundant
authorTor Lillqvist <tml@novell.com>
Sat, 7 Jun 2008 04:19:54 +0000 (04:19 +0000)
committerTor Lillqvist <tml@src.gnome.org>
Sat, 7 Jun 2008 04:19:54 +0000 (04:19 +0000)
2008-06-07  Tor Lillqvist  <tml@novell.com>

Bug 536990 - updateiconcache.c: 'close ()' is redundant

* gtk/updateiconcache.c (build_cache): Drop redundant close()
calls. fclose() on a fdopen()ed strema closes the underlying file
descriptor.

svn path=/trunk/; revision=20327

ChangeLog
gtk/updateiconcache.c

index 6d9ab218aca07aad277a0dedec24e8d2e63e80a0..fd381d3e4be1e6bb8ad5d4f47607430c064779ce 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2008-06-07  Tor Lillqvist  <tml@novell.com>
+
+       Bug 536990 - updateiconcache.c: 'close ()' is redundant
+
+       * gtk/updateiconcache.c (build_cache): Drop redundant close()
+       calls. fclose() on a fdopen()ed strema closes the underlying file
+       descriptor.
+
 2008-06-06  Matthias Clasen  <mclasen@redhat.com>
 
        Bug 536757 – regression: openoffice.org menus are placed at wrong
index a9381ce741fae24bfabdd2a447e6c3a3d90dceb0..58aaf5d87fe867d6de9c44b3ab8b3f91ce625445 100644 (file)
@@ -1475,7 +1475,6 @@ build_cache (const gchar *path)
       /* Empty table, just close and remove the file */
 
       fclose (cache);
-      close (fd);
       g_unlink (tmp_cache_path);
       exit (0);
     }
@@ -1483,7 +1482,6 @@ build_cache (const gchar *path)
   /* FIXME: Handle failure */
   retval = write_file (cache, files, directories);
   fclose (cache);
-  close (fd);
 
   g_list_foreach (directories, (GFunc)g_free, NULL);
   g_list_free (directories);